#include "my_io.h"

#include <linux/module.h>	/* modules */
#include <linux/fs.h>		/* file_operations */
#include <linux/uaccess.h>	/* copy_(to,from)_user */
#include <linux/init.h>		/* module_init, module_exit */
#include <linux/slab.h>		/* kmalloc */
#include <linux/cdev.h>		/* cdev */
#include <linux/device.h>	/* udev */
#include <linux/kthread.h>  	/* kernel thread */

#define NAME_COUNT_FILE "/var/tmp/my_file_count"


#define DEV_NAME "my_char_driver"
#define DISC_SIZE (size_t) 1024

int kernel_func(void *data);
static int my_open(struct inode *inode, struct file *file);
static int my_release(struct inode *inode, struct file *file);
static ssize_t my_read(struct file *file, char __user * buf, size_t lbuf, loff_t * ppos);
static ssize_t my_write(struct file *file, const char __user * buf, size_t lbuf, loff_t * ppos);
static loff_t my_llseek(struct file *file, loff_t offset, int orig);
static int my_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg);
static int file_count_exists(void);
static int update_count(void);
static int show_count(void);	
static int __init my_init(void);
static void __exit my_exit(void);
